package br.com.mtg.movethegarbage.framework;

import android.graphics.RectF;

public abstract class GUIBase
{
	protected float x, y;
	protected float w, h;

	public GUIBase(float _x, float _y, float _w, float _h)
	{
		x = _x;
		y = _y;
		w = _w;
		h = _h;
	}

	public GUIBase()
	{
		x = 0;
		y = 0;
		w = 0;
		h = 0;
	}

	public abstract void draw(Graphics graphics);

	public abstract void handleEvent(Object _event, Game game);

	public RectF getRect()
	{
		RectF rect = new RectF(x, y, x + w, y + h);
		rect.sort();
		return rect;
	}
}
